<%@ page language="java" contentType="text/html; charset=UTF-8"
    pageEncoding="UTF-8"%>
<%@page import="java.util.*"%>
<%@page import="com.infomanage.vo.*"%>
<%@page import="com.infomanage.util.*"%>
<%@page import="com.infomanage.po.*"%>
<%@page import="com.infomanage.po.AssessZdDept"%>
<%@page import="com.infomanage.enums.*"%>
<%@page import="com.infomanage.service.assess.AssessZdDeptService"%>
<%@page import="com.qs.service.*"%>
<%@page import="com.qs.vo.*"%>
<%@page import="com.qs.po.*"%>

<%  response.addDateHeader("Expires", 0);response.setHeader("Pragma","no-cache"); response.setHeader("Cache-Control","no-cache");%>
<%
	request.setCharacterEncoding("UTF-8");
	User user = (User) request.getSession().getAttribute(com.infomanage.util.Consts.LOGINED_USER);
	List<AssessZdDeptItem> list = null;
	String deptName = null;
	float totalPoints = 0;
	list = AssessZdDeptService.search(request, response, out);
	if(list != null && list.size() > 0){
		deptName = list.get(0).getDept().getPath();
	}
	
%>
<html>
<head>
	<META HTTP-EQUIV="Pragma" CONTENT="no-cache">
</head>
<body rightmargin="0" bottommargin="0" leftmargin="0" topmargin="0" onclick="parent.clickBody();" >
	<table width="100%">
		<tr>
			<td  align="center"><h2><%if(deptName != null){out.print(deptName);}else{out.print("中队");}%>考核评定表</h2></td>
		</tr>
	</table>
	<table border="1" align="center" cellpadding="0" cellspacing="0" width="90%" style="border-collapse: collapse" bordercolor="#000000">
		<tr>
			<th align="center">单位</th>
			<th align="center">时间</th>
			<th align="center">扣分描述</th>
			<th align="center">扣分</th>
		</tr>
		<%
			if(list != null){
				for(AssessZdDeptItem item : list){
					totalPoints += item.getBean().getDeductPoints();
		%>
			<tr>
				<td align="center"><%=item.getDept().getPath() %></td>
				<td align="center"><%=item.getBean().getAssessTime() %></td>
				<td align="center"><%=item.getBean().getAssessDeptId()%></td>
				<td align="center"><%=item.getBean().getDeductPoints() %></td>
			</tr>
		<%
				}
			}
		%>
		<tr>
			<td colspan="3" align="center">总计扣分</td>
			<td align="center"><%=totalPoints %></td>
		</tr>
	</table>
<br />
</body>
</html>
